import Tabs from '@theme/Tabs'
import TabItem from '@theme/TabItem'

<Tabs
  defaultValue="vcluster"
  values={[
    { label: 'vcluster', value: 'vcluster', },
    { label: 'helm', value: 'helm', },
    { label: 'kubectl', value: 'kubectl', },
  ]
}>
<TabItem value="vcluster">

Create a `values.yaml` file with the following lines:

```
securityContext:
  runAsUser: 12345
  runAsNonRoot: true
```

Then create the vcluster with the following command:
```
vcluster create -f values.yaml
```

</TabItem>
<TabItem value="helm">

Update the `vcluster.yaml` file described in the [deployment guide](../getting-started/deployment). 

You will need to add the `securityContext` block as shown below:

```yaml
securityContext:
  runAsUser: 12345
  runAsNonRoot: true
```

Then, install helm chart using `vcluster.yaml` for chart values as described in the [deployment guide](../getting-started/deployment). 

</TabItem>
<TabItem value="kubectl">

Update the `vcluster-1.yaml` file described in the [deployment guide](../getting-started/deployment). 

You will need to add the `securityContext` blocks to the containers as shown below:

```yaml {10-12,15-17}
apiVersion: apps/v1
kind: StatefulSet
metadata:
  ...
spec:
  template:
    spec:
      containers:
      - name: virtual-cluster
        securityContext:
          runAsUser: 12345
          runAsNonRoot: true
        ...
      - name: syncer
        securityContext:
          runAsUser: 12345
          runAsNonRoot: true
        ...
```
</TabItem>
</Tabs>